package www.itheima.compiterdemo;

public class computer {
    public void something(USB wow){
        wow.connect();
        if(wow instanceof mouse){
           mouse wo=(mouse)wow;
           wo.click();
        }
        else if(wow instanceof keyboard){
            keyboard wo=(keyboard)wow;
            wo.click();
        }
        wow.unconnect();
    }
}
